import {ref, Ref} from "vue"

interface CollapseReturn {
    collapse: Ref<boolean>
    setCollapse: () => void
}

export function useCollapse(): CollapseReturn {
    const collapse = ref(false)

    function setCollapse() {
        collapse.value = !collapse.value
    }

    return {
        collapse,
        setCollapse
    }
}